﻿<UserControl x:Class="EasySL.Controls.TextScroller"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
    >
    <UserControl.Resources>
        <Storyboard x:Name="scrollStoryboard" >
            <DoubleAnimation x:Name="daMoveMessage"
                    Storyboard.TargetName="message" 
                    Storyboard.TargetProperty="(Canvas.Left)" 
                    To="-140" 
                    Duration="0:0:5"
                    RepeatBehavior="Forever"
                    />
        </Storyboard>
    </UserControl.Resources>
    <Canvas Width="180" Height="20" x:Name="LayoutRoot" Clip="M 0,0 h 180 v 20 h -180 z">
        <Border Opacity="0.6" BorderBrush="Gray" BorderThickness="1" Background="White" Width="180" Height="18"/>
        <TextBlock 
            x:Name="message" 
            Text="等待播放...." 
            Foreground="Black"
            TextWrapping="NoWrap"
            Canvas.Left="0">
        </TextBlock>
    </Canvas>
</UserControl>
